package com.创建型模式.单例模式.猪八戒;

/**
 * 饿汉猪八接
 */
public class BaJie {
    public final static BaJie instance  = new BaJie();
    private BaJie(){
        System.out.println("我是猪八戒，老猪从天而降了。");
    }
    public static BaJie getInstance(){
        return instance;
    }
}
